$(function(){
	member=getEntity("memberInfo");
	if(member){	
		$(".finput").val(member.mName);
	}
	
	$('.moSex li').click(function(){
		var value = $(this).text();
		var mSex="";
		if(value=="男"){
			mSex="0";
		}else{
			mSex="1";
		}
		$('.moSex').css({display:'none'});
	    $('.mengban').css({display:'none'});
	    $.ajax({
			type:"post",
			url:rootPath+"/member/upMemberInfo",
			data:{'mSex':mSex,'mId':member.mId},
			success:function(data){
				window.location.href=rootPath+"/member/personalData";
			}
		})
	});
	
	
})

function modifyNickName(){
	var mName=$(".finput").val();
	$.ajax({
		type:"post",
		url:rootPath+"/member/upMemberInfo",
		data:{'mName':mName,'mId':member.mId},
		success:function(data){
			window.location.href=rootPath+"/member/personalData";
		}
	})
}